<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>教育资源-教师资源</title>
	<link rel="stylesheet" href="./css/common.css">
	<link rel="stylesheet" href="./css/publishDetail.css">	
	<link href="./resource/resFilesCss/z_netdisk.css" rel="stylesheet" type="text/css">
	<link rel="stylesheet" href="./ztress/zTreeStyle.css">
	<link href="./resource/resFilesCss/public.css" rel="stylesheet" type="text/css">
</head>
<body>
<div id ="header" ></div>
<div class="midbody clearfix" >
	<div class="titShow">
		<a href="http://www.huijiaoyun.com/index.php?r=center/person/index">空间首页</a>
		<em>&gt;</em>
		<a href="newNetdisk.htm">我的云盘</a>
		<em>&gt;</em>
		资源发布
	</div>
	<div class="devTit">
		<strong class="fl">资源发布</strong>
		<span class="c888">注：资源发布成功后，所有用户可阅读和下载</span>
	</div>
	<div class="midMain">
		<div class="boxDev">
			<div class="tit">
				<p>
					<span class="image" name="fileOfExt"></span>
					<a href="javascript:void(0);" class="name_d" title="2223.png" style="display: inline-block;">2223.png</a>
					<em class='cmmbox dis_none'>
						<input type="text" name="resTitleNew" value="2223.png" 
						placeholder="2223.png" class="fileinp ndinp">
						<i class="r_btn"></i>
						<i class="d_btn"></i>
					</em>
					<span class="redTip22 dis_none">
						<i class="redtig">平台资源库已有类似资源，请勿重复发布！</i>
					</span>
				</p>
				<p class="tool">
					<a href="javascript:;" class="edit"></a>
				</p>
			</div>
		</div>
		<div class="botCont">
			<div class="twoTit">
				<strong>
					统一编目信息
				</strong>
			</div>
			<form class="fbLIst" >
				<dl class="clearfix">
					<dt>类型：</dt>
					<dd>
						<div class="ui-select">
					        <p class="moniSelect">
					        	教案
					        	<span class="icon-down"></span>
					        </p>
					        <select name="" id="">
					            <option value="教案">教案</option>
					            <option value="课件">课件</option>
					            <option value="习题">习题</option>
					            <option value="素材">素材</option>
					        </select>
					    </div>
					    <div class="redTip">*</div>
					</dd>
				</dl>
				<dl class="clearfix">
					<dt>目录：</dt>
					<dd >
						<div class="ui-select">
					        <p class="moniSelect">
					        	小学
					        	<span class="icon-down"></span>
					        </p>
					        <select name="" id="">
					            <option value="教案">小学</option>
					            <option value="课件">初中</option>
					            <option value="习题">高中</option>
					        </select>
					    </div>
					    <div class="redTip">*</div>
					</dd>
					<dd >
						<div class="ui-select">
					        <p class="moniSelect">
					        	语文
					        	<span class="icon-down"></span>
					        </p>
					        <select name="" id="">
					            <option value="语文">语文</option>
					            <option value="数学">数学</option>
					            <option value="音乐">音乐</option>
					        </select>
					    </div>
					    <div class="redTip">*</div>
					</dd>
					<dd >
						<div class="ui-select">
					        <p class="moniSelect">
					        	人教课标版
					        	<span class="icon-down"></span>
					        </p>
					        <select name="" id="">
					            <option value="人教课标版">人教课标版</option>
					            <option value="北师大课标版">北师大课标版</option>
					            <option value="苏教课标版">苏教课标版</option>
					        </select>
					    </div>
					    <div class="redTip">*</div>
					</dd>
					<dd >
						<div class="ui-select">
					        <p class="moniSelect">
					        	请选择册别
					        	<span class="icon-down"></span>
					        </p>
					        <select name="" id="">
					            <option value="七年级上册">七年级上册</option>
					            <option value="七年级下册">七年级下册</option>
					            <option value="八年级下册">八年级下册</option>
					        </select>
					    </div>
					    <div class="redTip">*</div>
					</dd>
				</dl>
				<dl class="clearfix">
					<dt>章节:</dt>
					<dd >
						<div class="borderKuang test-1">
							<ul id="treeDemo" class="ztree">	
							</ul>
						</div>
					</dd>
				</dl>
				<dl class="clearfix">
					<dt>关键词:</dt>
					<dd>
						<input type="text" id="keyword" placeholder="选填，建议为您的文档填写关键词,多个关键词用逗号分隔" class="ndinp w757">
					</dd>
				</dl>
				<dl class="clearfix">
					<dt>关键词:</dt>
					<dd>
						<textarea id="intro" placeholder="选填，简要介绍资源的主要内容，方便资源被更多人浏览和下载" class="mstext w757"></textarea>
					</dd>
				</dl>
				<p class="t_c">
					<input type="button" name="doPackProduct" value="发布" class="xy_tcbtn_b" onclick="location.href='resource.html?type=publish'">
					<input type="button" value="返回" class="xy_tcbtn_g" onclick="doBack()">
				</p>
			</form>
		</div>
	</div>
</div>
<div class="footerBot"></div>
<script src="./js/jquery.js"></script>
<script src="./js/fxtpl.plus.js"></script>
<script src="./ztress/jquery.ztree.core.js"></script>


<script>

	var dataClass = {"dataClass":6};
	var header = Fxtpl.render('./weight/header.html',dataClass);
	$('#header').html(header);
	
	// 添加交互
	$(".tool a.edit").on("click",function(){
		if( $(this).parents(".tit").find(".cmmbox").hasClass("dis_none")){
			$(this).parents(".tit").find(".cmmbox").removeClass("dis_none");
			$(this).parents(".tit").find(".name_d").css("display","none");
		}
	});

	$(".r_btn").on("click",function(){
           var inputShuru = $(this).siblings(".ndinp").val();
               inputShuru=inputShuru||"新建文件夹";
            $(this).parents(".tit ").find(".name_d").html(inputShuru);
           $(this).parents(".tit").find(".name_d").css("display","inline-block");
           $(this).parents(".cmmbox").addClass("dis_none");
    });

    $(".d_btn").on("click",function(){
    	$(this).parents(".tit").find(".name_d").css("display","inline-block");
    	$(this).parents(".cmmbox").addClass("dis_none");
    });

    $(".ui-select select").change(function(){
       $(this).prev(".moniSelect").html($(this).find("option:selected").val()+'<i class="icon-down lMar10"></i>');
    })

    // zTree里面的内容
    var setting = {
			view: {
				showLine: false
			},
			data: {
				simpleData: {
					enable: true
				}
			}
		};
		var zNodes =[
			{ id:1, pId:0, name:"父节点1 - 展开", open:true},
			{ id:11, pId:1, name:"父节点11 - 折叠"},
			{ id:111, pId:11, name:"叶子节点111"},
			{ id:112, pId:11, name:"叶子节点112"},
			{ id:113, pId:11, name:"叶子节点113"},
			{ id:114, pId:11, name:"叶子节点114"},
			{ id:12, pId:1, name:"父节点12 - 折叠"},
			{ id:121, pId:12, name:"叶子节点121"},
			{ id:122, pId:12, name:"叶子节点122"},
			{ id:123, pId:12, name:"叶子节点123"},
			{ id:124, pId:12, name:"叶子节点124"},
			{ id:13, pId:1, name:"父节点13 -折叠", isParent:true},
			{ id:131, pId:13, name:"叶子节点131"},
			{ id:132, pId:13, name:"叶子节点132"},
			{ id:133, pId:13, name:"叶子节点133"},
			{ id:134, pId:13, name:"叶子节点134"},
			{ id:14, pId:1, name:"父节点14 -折叠", isParent:true},
			{ id:141, pId:14, name:"叶子节点141"},
			{ id:142, pId:14, name:"叶子节点142"},
			{ id:143, pId:14, name:"叶子节点143"},
			{ id:144, pId:14, name:"叶子节点144"},
		];
		$(document).ready(function(){
			$.fn.zTree.init($("#treeDemo"), setting, zNodes);
		});
</script>
</body>	
</html>